/*
* PLC.java
* PLC for all the track controllers
* Author: Nikolas Parshook
* Date Created: 2012-12-13
* Date Last Updated: 2012-12-13
*/

/**
* PLC for all the track controllers
* @author Nikolas Parshook
*/
public class PLC {

	public PLC(){}
	
	
	/**
	* runs a blocks plc
	* @param Block
	*/
	public void run(Block b)
	{
		if (b.type == 2){}
		if (b.type == 3)
		{
			if(b.prev.occupied || b.next.occupied)
				b.crossingOn = true;
			else
				b.crossingOn = false;
		}
	}
	
}
